<style type="text/css"> 
.memberLeft{width:580px;float:left;   overflow: hidden;}
.memberRight{width:265px;float:left;  }
.camera{width:650px;height:200px;   position: absolute;
    z-index: 999;  display: none;top:100px;left:180px;}
.camera #webcam{float:left;}
.camera .mycanvas{float:left;  width:200px;height:200px;}
.camera .camera_bottom{clear:both;}
#MemReg_fileQueue{height:100px;width:300px;}

</style>
<link href="../Public/css/uploadify.css" rel="stylesheet" type="text/css" />	
<script src="../Public/js/jquery.webcam.js" type="text/javascript"> </script>
<script src="../Public/js/webcamComm.js" type="text/javascript"> </script>
<script type="text/javascript" src="../Public/js/swfobject.js"></script>
<script type="text/javascript" src="../Public/js/jquery.uploadify.v2.1.0.min.js"></script>
<script type="text/javascript">
var sessionId="{$ _COOKIE ["PHPSESSID"]}";
$(document).ready(function() {
	$("#uploadify").uploadify({
	    'buttonImg':'../Public/images/selectImg.jpg',
		'uploader'       : '../Public/swf/uploadify.swf',
		'script'         : '/Member/savephoto',
		'cancelImg'      : '../Public/images/cancel.png',
		'folder'         : 'uploads',
		'queueID'        : 'fileQueue',
		'method'         : 'GET',
		'scriptData'  : {PHPSESSID:sessionId},
		'auto'           : true,
		'multi'          : true,
		'sizeLimit'      : 3512000,
		'width'          : 300,
		'fileDesc'       :'支持的格式:jpg,jpeg,gif,png,bmp',
		'fileExt'        :'*.jpg;*.jpeg;*.gif;*.png;*.bmp;*.swf',
 'onError': function (event, ID, fileObj, errorObj) {
if (errorObj.type == "File Size")
alert("对不起，上传的图片不能超过500K");
else
alert(errorObj.type + ' Error: ' + errorObj.info);
},
'onComplete': function (event, ID, fileObj, response, data) {
if (response != "0") {
$("#MemReg_Avatar").attr("src", response);
$("#MemReg_Photo").val(response);
}
} 
	});
});
	</script>
<div class="pageContent">
  <FORM id="form" action="__URL__/insert/navTabId/{$Think.const.MODULE_NAME}" method="post" enctype="multipart/form-data"  class="pageForm required-validate" onsubmit="return validateCallback(this, dialogAjaxDone)">
<DIV class="divContentBox">
<div class="memberLeft">
<DIV id="Head" class="divContentHead">会员登记</DIV>
<DIV id="div_errorMsg" class="diverrMsg"></DIV>
<TABLE border="0" cellSpacing="0" cellPadding="0">
  <TBODY>
  <TR>
    <TD>
      <TABLE style="margin: 10px 0px 10px 10px; width: 600px;height:300px; float: left; _margin-left: 10px;" 
      class="formTable" border="0" cellSpacing="1" cellPadding="0">
        <TBODY>
        <TR>
          <TD style="width: 80px;" align="right">                            
            会员卡号：                        </TD>
          <TD colSpan="3"><INPUT style="width: 140px;" id="cardnumber"  name="cardnumber" type="text">&nbsp;&nbsp;<INPUT id="ICCardHairpin" value="发卡" type="button"><INPUT 
            id="ID" name="ID" type="hidden"></TD></TR>
        <TR>
          <TD style="width: 80px;" align="right">会员姓名：                        
          </TD>
          <TD><INPUT style="width: 140px;" id="membername" name="membername" 
            type="text"></TD>
          <TD style="width: 80px;" align="right">手机号码：                        
          </TD>
          <TD><INPUT style="width: 140px;" id="mobile" name="mobile" 
            type="text"></TD></TR>
        <TR>
          <TD style="width: 80px;" align="right">会员性别：                        
          </TD>
          <TD>                            男<INPUT id="Man" name="gender" 
            value="男" type="radio">女<INPUT id="Girl" name="gender" 
            value="女" type="radio"></TD>
          <TD style="width: 80px;" align="right">                            
            固定电话：                        </TD>
          <TD><INPUT style="width: 140px;" id="phone" name="phone" 
            type="text"></TD></TR>
        <TR>
          <TD align="right">会员等级：                        </TD>
          <TD><SELECT id="groupid" name="groupid"><OPTION 
              value="">请选择</OPTION><OPTION value="11">年卡</OPTION><OPTION value="9">月卡</OPTION><OPTION 
              value="10">4</OPTION></SELECT></TD>
          <TD align="right">会员生日：                        </TD>
          <TD><LABEL><INPUT id="birthdaytype" name="birthdaytype" 
            value="0" type="radio">公历</LABEL><LABEL><INPUT id="birthdaytype" 
            name="birthdaytype" value="1" type="radio">农历</LABEL><SELECT 
            id="birthday_Month" name="birthday_Month"><OPTION 
              selected="selected" value="0">--</OPTION><OPTION 
              value="1">1月</OPTION><OPTION value="2">2月</OPTION><OPTION value="3">3月</OPTION><OPTION 
              value="4">4月</OPTION><OPTION value="5">5月</OPTION><OPTION value="6">6月</OPTION><OPTION 
              value="7">7月</OPTION><OPTION value="8">8月</OPTION><OPTION value="9">9月</OPTION><OPTION 
              value="10">10月</OPTION><OPTION value="11">11月</OPTION><OPTION 
              value="12">12月</OPTION></SELECT><SELECT id="birthday_Day" 
            name="birthday_Day"><OPTION value="0">--</OPTION><OPTION 
              value="1">1日</OPTION><OPTION value="2">2日</OPTION><OPTION value="3">3日</OPTION><OPTION 
              value="4">4日</OPTION><OPTION value="5">5日</OPTION><OPTION value="6">6日</OPTION><OPTION 
              value="7">7日</OPTION><OPTION value="8">8日</OPTION><OPTION value="9">9日</OPTION><OPTION 
              value="10">10日</OPTION><OPTION value="11">11日</OPTION><OPTION 
              value="12">12日</OPTION><OPTION value="13">13日</OPTION><OPTION 
              value="14">14日</OPTION><OPTION value="15">15日</OPTION><OPTION 
              value="16">16日</OPTION><OPTION value="17">17日</OPTION><OPTION 
              value="18">18日</OPTION><OPTION value="19">19日</OPTION><OPTION 
              value="20">20日</OPTION><OPTION value="21">21日</OPTION><OPTION 
              value="22">22日</OPTION><OPTION value="23">23日</OPTION><OPTION 
              value="24">24日</OPTION><OPTION value="25">25日</OPTION><OPTION 
              value="26">26日</OPTION><OPTION value="27">27日</OPTION><OPTION 
              value="28">28日</OPTION><OPTION value="29">29日</OPTION><OPTION 
              value="30">30日</OPTION><OPTION value="31">31日</OPTION>
</SELECT></TD></TR>
        <TR>
          <TD align="right">过期时间：                        </TD>
          <TD colSpan="3"><INPUT style="width: 140px;" id="pastdate" 
            name="pastdate" type="text"><LABEL><INPUT id="IsPast" 
            name="ispast" type="checkbox">永久有效（不设置过期时间）</LABEL></TD></TR>
        <TR>
          <TD align="right">                            会员状态：                  
                  </TD>
          <TD><SELECT id="status" name="status"><OPTION value="0">正常</OPTION><OPTION 
              value="1">锁定</OPTION><OPTION value="2">挂失</OPTION></SELECT></TD>
          <TD></TD>
          <TD></TD></TR>
        <TR>
          <TD align="right">会员付费：                        </TD>
          <TD><INPUT style="width: 60px;" id="memberpay" name="memberpay" value="0" type="text"></TD>
          <TD></TD>
          <TD></TD></TR>
        <TR>
          <TD align="right">账户余额：                        </TD>
          <TD><INPUT style="width: 60px; background-color: rgb(238, 238, 238);" 
            id="money"  name="money" 
            readOnly="true" value="0" type="text"></TD>
          <TD align="right">账户积分：                        </TD>
          <TD><INPUT style="width: 60px; background-color: rgb(238, 238, 238);" 
            id="point"  name="point" 
            readOnly="true" value="0" type="text"></TD></TR>
        <TR>
          <TD align="right">推荐人：                        </TD>
          <TD colSpan="3"><INPUT style="width: 140px;" id="referer" 
            name="referer" type="text"><SPAN 
            id="referer_msg"></SPAN><INPUT id="refererid" name="refererid" 
            type="hidden"><INPUT id="referername" name="referername" 
            type="hidden"></TD></TR>
        <TR>
          <TD style="height: 3px; overflow: hidden; background-color: rgb(204, 204, 204);" 
          colSpan="4"></TD></TR>
        <!--<TBODY id="Tbody_Custom">
        <TR>
          <TD align="right"><SPAN 
          id="Custom_T_C_1111">1111111</SPAN>：</TD>
          <TD><SELECT id="Custom_C_1111" name="Custom_C_1111" 
            isnull="True"><OPTION value="a b c">a b c</OPTION></SELECT></TD>
          <TD align="right"><SPAN 
          id="Custom_T_C_22222">2222222</SPAN>：</TD>
          <TD><INPUT id="Custom_C_22222" name="Custom_C_22222" 
            type="text" isnull="True"></TD></TR>
        <TR>
          <TD align="right"><SPAN 
          id="Custom_T_C_33333">3333333</SPAN>：</TD>
          <TD><INPUT id="Custom_C_33333" name="Custom_C_33333" 
            type="text" isnull="True"></TD>
          <TD align="right"><SPAN id="Custom_T_C_1">123</SPAN>：</TD>
          <TD><INPUT id="Custom_C_1" name="Custom_C_1" type="text" 
            isnull="True"></TD></TR>
        <TR>
          <TD></TD>
          <TD></TD></TR>
<SCRIPT></SCRIPT>
        </TBODY>-->
        <TBODY>
        <TR>
          <TD style="padding: 5px; text-align: center;" colSpan="4"><INPUT id="Button_Submit" class="ButtonLong" value="保存数据" type="submit"></TD></TR></TBODY></TABLE>
          <!--头像部分-->
      <!--<DIV style="margin: 10px; border: 1px solid rgb(204, 204, 204); width: 250px; float: left;">
      <DIV style="text-align: center; margin-top: 10px;">
      <DIV id="MemList_AdvancedMemberSXT" class="p_advMemSearch divModalBox">
      <OBJECT id="My_Cam" codeBase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0" 
      classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" width="616" align="middle" 
      height="283" viewastext="在线拍照"><PARAM name="allowScriptAccess" value="sameDomain"><PARAM 
      name="movie" value="../inc/PhotoOnline.swf"><PARAM name="quality" value="high"><PARAM 
      name="bgcolor" value="#ffffff"><EMBED height="283" name="My_Cam" type="application/x-shockwave-flash" 
      align="middle" pluginspage="http://www.macromedia.com/go/getflashplayer" 
      width="616" src="../inc/PhotoOnline.swf" quality="high" bgcolor="#ffffff" 
      allowscriptaccess="sameDomain"></OBJECT></DIV><IMG id="Avatar" src="添加新会员_files/nophoto.gif"><INPUT 
      id="Photo" name="Photo" type="hidden"></DIV>
      <DIV style="height: 30px; margin-top: 10px;">
      <DIV 
      style="width: 76px; height: 25px; float: left; _margin-left: 20px;"><INPUT 
      style="display: none;" id="uploadify" name="uploadify" type="file"></DIV>
      <DIV style="width: 83px; height: 25px; margin-top: 0px; float: left;"><INPUT class="button" onClick="javascript:$('#uploadify').uploadifyUpload();" value="上传图片" type="button"></DIV>
      <DIV style="height: 25px; margin-top: 0px; float: left;"><INPUT id="dakaisxt" class="button" value="打开摄像头" type="button"></DIV></DIV>
    <DIV id="fileQueue"></DIV></DIV>--></TD></TR></TBODY></TABLE>
</div>	

<div class="memberRight">


<div style=" width:248px; border:1px solid #ccc; margin:3px; float:left;">
                        <div style=" text-align:center; margin-top:10px;">
                            <div class="p_advMemSearch divModalBox jqmID1" id="MemList_AdvancedMemberSXT" style="z-index: 1; display: none;">
                         <object width="616" align="middle" height="283" viewastext="在线拍照" codebase="http://fpdownload.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=8,0,0,0" classid="clsid:d27cdb6e-ae6d-11cf-96b8-444553540000" id="My_Cam">
                <param value="sameDomain" name="allowScriptAccess">
                <param value="../inc/PhotoOnline.swf" name="movie">
                <param value="high" name="quality">
                <param value="#ffffff" name="bgcolor">
                <embed width="616" align="middle" height="283" type="application/x-shockwave-flash" src="../inc/PhotoOnline.swf" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" name="My_Cam" bgcolor="#ffffff" allowscriptaccess="sameDomain">
            </object>
                            </div>
                            <img id="MemReg_Avatar" src="../Public/images/nophoto.gif">
                            <input type="hidden" id="MemReg_Photo" name="MemReg_Photo">
                        </div>
                        <div style=" margin-top:10px; height:30px;width:238px;overflow:hidden;">
                            <div style="width:70px;height:25px; float:left;margin-left:10px; ">
									
						    <input type="file" name="uploadify" id="uploadify" style=" display:none;" />
							
							</div>
                            <div style=" width:75px; float:left; height:25px; margin-top:0px;margin-left: 5px;">                                <input type="button" value="打开摄像头" onclick="camaShow()"  id="dakaisxt"></div>
                        </div>
                        <div id="fileQueue"></div>
                    </div>


</div>
	
	</DIV>
</FORM>
	
</div>

<div class="camera">
<div>
<div id="webcam"></div>
<div class"mycanvas">
<img src="" id="resultImg" alt="" />
</div>
</div>
<div class="camera_bottom">
<input type="button" value="拍照" onclick="webcam.capture();" />
<input type="button" value="关闭" onclick="camaClose();" />
</div>
</div>

<script type="text/javascript">
function camaShow(){
$(".camera").show();
startCa();
}
function camaClose(){
$(".camera").hide();
$("#XwebcamXobjectX").remove();
}
</script>
